#!/bin/bash
apt clean && apt update -y && apt upgrade -y 
apt-get install --no-install-recommends -y \
apt-transport-https apt-utils ca-certificates gnupg2 curl wget \
software-properties-common iproute2 iputils-ping git git-lfs \
bash-completion build-essential vim terminator sudo tzdata ssh
locales && locale-gen en_US.UTF-8 && \
echo LANG=$LANG > /etc/default/locale && \
update-locale LANG=$LANG
# Set up the timezone
echo $TZ > /etc/timezone && \
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime \
dpkg-reconfigure tzdata

mkdir /var/run/sshd
sed -i -e '/#PermitRootLogin/c\PermitRootLogin yes' \
-e '/X11Forwarding/c\X11Forwarding yes' /etc/ssh/sshd_config
sed -i '/pam_loginuid.so/c\session optional pam_loginuid.so' /etc/pam.d/sshd
# add conda in PATH if it exists
echo "export PATH=\$PATH:/opt/conda/bin" > /etc/profile.d/conda.sh